import { http } from "@/utils/http";
import { baseUrlApi } from "./utils";

type Result = {
  page: any;
  result: any
};


/** 获取消息通知列表 */
export const getFindmessagelist = () => {
  return http.request<Result>("get", baseUrlApi(`/api/backend/message/findmessagelist`));
};

/** 消息已经阅接口 */
export const yymessage = (id) => {
  return http.request<Result>("get", baseUrlApi(`/api/backend/message/yymessage/${id}`));
};


/** 分页查询文档申请消息 */
export const getSelmessagepage = (data?: object) => {
  return http.request<Result>("post", baseUrlApi("/api/backend/message/selmessagepage"), { data });
};

/** 删除文档申请消息 */
export const delmessage = (userid?: string | number) => {
  return http.request<Result>("delete", baseUrlApi(`/api/backend/message/delmessage/${userid}`));
};


/** 修改文档申请状态 */
export const changemessage = (data?: object) => {
  return http.request<Result>("post", baseUrlApi("/api/backend/message/changemessage"), { data });
};




